//
//  ColorConfig.swift
//  Trans
//
//  Created by zcj on 2024/10/30.
//

import SwiftUI

var kcolors:ColorConfigProtocol{
    ColorsConfig.whiteColors
}
protocol ColorConfigProtocol {
    var backgroundColor: Color { get }
    var buttonBackgroundColor :Color{get}
    var textColor: Color { get }
    var text2Color: Color { get }
    var lineColor: Color { get }
}

struct ColorsConfig {
    struct WhiteColors: ColorConfigProtocol {
        let backgroundColor = Color(hex:"#ffeeeeee")
        let textColor = Color.black
        let text2Color = Color.black.opacity(0.5)
        let buttonBackgroundColor = Color.blue
        let lineColor = Color.black
    }

    struct BlackColors: ColorConfigProtocol {
        let backgroundColor = Color.black
        let textColor = Color.white
        let text2Color = Color(hex:"#dddddddd")
        let buttonBackgroundColor = Color.blue
        let lineColor = Color.gray
    }

    static let whiteColors = WhiteColors()
    static let blackColors = BlackColors()
}

